# Maintainer: Konstantin Podsvirov <konstantin@podsvirov.su>

_realname=eslint
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=9.27.0
pkgrel=1
pkgdesc='An AST-based pattern checker for JavaScript (mingw-w64)'
arch=('any')
mingw_arch=('mingw64' 'ucrt64' 'clang64' 'clangarm64')
url='https://eslint.org'
msys2_repository_url='https://github.com/eslint/eslint'
license=('spdx:MIT')
depends=("${MINGW_PACKAGE_PREFIX}-nodejs")
source=("https://registry.npmjs.org/${_realname}/-/${_realname}-${pkgver}.tgz")
sha256sums=('38dcb33cc47fad5055703b90290ab9c5532d2f720d90458a7e118fbdc97a00f1')
noextract=("${_realname}-${pkgver}.tgz")

package() {
  "${MINGW_PREFIX}"/bin/npm install -g \
    --cache "${srcdir}/npm-cache" \
    --prefix "${pkgdir}${MINGW_PREFIX}" \
    "${srcdir}/${_realname}-${pkgver}.tgz"
}
